package club.janna.jrpc.service.demo.service.impl;

import club.janna.jrpc.annotation.JRPCService;
import club.janna.jrpc.service.demo.result.ResultStatus;
import club.janna.jrpc.service.demo.result.SMSResult;
import club.janna.jrpc.service.demo.service.SMSService;
import lombok.extern.slf4j.Slf4j;

/**
 * @author Panbo.Guo
 */
@Slf4j
@JRPCService
public class SMSServiceImpl implements SMSService {
    @Override
    public SMSResult sendMsg(String phone, String msg) {
        log.info("发送短信，to {}, msg -> {}", phone, msg);
        SMSResult result = new SMSResult();
        result.setStatus(ResultStatus.SUCCESS);
        result.setMsg("发送成功");
        result.setId(1L);
        return result;
    }
}
